﻿HmJS.$Import('core.element');

HmJS.register('demo.module.moo.drag.move', function ($ns) {
	var that = {};

	that.todo = function () {

		new Drag.Move($('drag'), {

			container: $('container'),

			droppables: $$('.drop'),

			onEnter: function (element, droppable) {
				droppable.setStyle('background', '#E79D35');
			},

			onLeave: function (element, droppable) {
				droppable.setStyle('background', '#6B7B95');
			},

			onDrop: function (element, droppable) {
				if (droppable) droppable.setStyle('background', '#C17878');
			}

		});

	};

	return that;
});
